package cz.possoft.serializable.clovece.cube;

import java.util.Random;

/**
 * Implementation based on random number. This will be used in production environment in game, 
 * because it's normal that it's based on random numbers.
 * 
 * @author <a href="mailto:mposolda@gmail.com">Marek Posolda</a>
 */
public class RandomCubeGenerator implements CubeGenerator
{
   
   /**
    * {@inheritDoc}
    */
   public int nextValue()
   {      
      // generate random number
      Random rand = new Random();
      int number = rand.nextInt(6) + 1;
      return number;
   }

}

